﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ContacterManage.aspx.cs" Inherits="GreatB2C.Web.Manage.CRM.Contacter.ContacterManage" %>

<%@ Register assembly="AspPagerControl" namespace="AspPagerControl" tagprefix="AspPagerControl" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <input type="hidden" id="programid" name="programid" />
    <table width="100%" border="0" cellpadding="0" cellspacing="0" style="background-color: #f2f9ff;">
        <tr class="nav">
            <td width="2%" align="left">
                <img alt="" src="" />
            </td>
            <td width="96%">
                当前位置：客户关系管理->联系人管理->联系人列表
            </td>
        </tr>
    </table>
    <table width="100%" cellspacing="0" cellpadding="0" class="line">
        <tr>
            <td style="height: 8px;">
            </td>
        </tr>
    </table>
                <asp:GridView ID="gdvList" runat="server" 
        AutoGenerateColumns="False" Width="100%"
                    CssClass="GridViewStyle" 
        AllowPaging="True" onrowcommand="gdvList_RowCommand">
                    <HeaderStyle CssClass="GridViewHeaderStyle" />
                    <RowStyle CssClass="GridViewRowStyle" />
                    <AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
                    <SelectedRowStyle CssClass="GridViewSelectedRowStyle" />
                    <Columns>
                        <asp:BoundField HeaderText="编号" DataField="ContacterId" Visible="False" />
                        <%--  <asp:TemplateField HeaderText="&lt;input type='checkbox' id='chk' name='chk' onclick='checkJs(this.checked);'  /&gt;全选">
                            <ItemTemplate>
                                <input type="checkbox" id="checkboxname" name="checkboxname" value=''
                                    onclick='SingleCheckJs();' />
                            </ItemTemplate>
                        </asp:TemplateField>--%>
                        <asp:TemplateField HeaderText="序号">
                            <ItemTemplate>
                                <%# (Container.DataItemIndex+1).ToString()%>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:BoundField HeaderText="姓名" DataField="TrueName" />
                        <asp:BoundField HeaderText="称谓" DataField="Title" />
                        <asp:BoundField HeaderText="工作电话" DataField="OfficePhone" />
                        <asp:BoundField HeaderText="手机" DataField="Mobile" />
                        <asp:BoundField HeaderText="Email地址" DataField="Email" />
                        <asp:TemplateField HeaderText="类型">
                           <ItemTemplate>
                              <%# (int)Eval("UserType") == 1 ? "主联系人" : "其它联系人"%>
                           </ItemTemplate>
                            <HeaderStyle Width="10%" />
                        </asp:TemplateField>
                        <asp:HyperLinkField DataNavigateUrlFields="ClientId" HeaderText="对应客户" />
                        <asp:TemplateField HeaderText="操作">
                            <ItemTemplate>
                                <table border="0" cellpadding="0" cellspacing="0" width="100%">
                                    <tr align="center">
                                        <td>
                                            <asp:LinkButton ID="lbView" runat="server" 
                                                CommandArgument='<%#Eval("ContacterId")%>' CommandName="ViewCommand">查看</asp:LinkButton>
                                        </td>
                                        <td>
                                            <asp:LinkButton ID="lbUpdate" runat="server" 
                                                CommandArgument='<%#Eval("ContacterId")%>' CommandName="UpdateProgram">修改</asp:LinkButton>
                                        </td>
                                        <td>
                                            <asp:LinkButton ID="lbDelete" runat="server" 
                                                CommandArgument='<%#Eval("ContacterId")%>' CommandName="DeleteCommand" 
                                                OnClientClick="return  ConfirmDelete();">删除</asp:LinkButton>
                                        </td>
                                    </tr>
                                </table>
                            </ItemTemplate>
                            <ControlStyle Width="70px" />
                            <ItemStyle HorizontalAlign="Center" Width="210px" Wrap="True" />
                        </asp:TemplateField>
                    </Columns>
                </asp:GridView>
       <table width="100%">
        <tr>
            <td>
<AspPagerControl:AspNetPager ID="AspNetPager1" runat="server" FirstPageText="首页"
                        LastPageText="尾页" NextPageText="下一页" OnPageChanged="AspNetPager1_PageChanged"
                        PrevPageText="上一页" SubmitButtonText="Go" TextAfterPageIndexBox="页" TextBeforePageIndexBox="转到"
                        CustomInfoHTML="&nbsp;" 
                        PageSize="10" ShowCustomInfoSection="Left" AlwaysShow="True" 
                         CurrentPageButtonPosition="Beginning"  ShowPageIndexBox="Never">
                    </AspPagerControl:AspNetPager>
            </td>
        </tr>
    </table> 
    </form>
</body>
</html>
